<!DOCTYPE html>
<html lang="zh-CN">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>系统维护 - 学知题库</title>
    <link href="../assets/css/app.css" rel="stylesheet">
    <link href="../assets/css/font-awesome.min.css" rel="stylesheet">
    <script src="../assets/js/chart.umd.min.js"></script>
    
    <!-- Tailwind 配置 - 已合并到公共配置文件 -->
    <!-- 
    <script>
        tailwind.config = {
            theme: {
                extend: {
                    colors: {
                        primary: '#165DFF',
                        secondary: '#36CBCB',
                        accent: '#FF7D00',
                        neutral: '#F5F7FA',
                        'neutral-dark': '#4E5969',
                        success: '#00B42A',
                        warning: '#FF7D00',
                        danger: '#F53F3F',
                    },
                    fontFamily: {
                        inter: ['Inter', 'system-ui', 'sans-serif'],
                    },
                }
            }
        }
    </script>
    -->
    
    <!-- 工具类样式 - 已合并到 src/input.css -->
    <!-- 
    <style type="text/tailwindcss">
        @layer utilities {
            .content-auto {
                content-visibility: auto;
            }
            .scrollbar-hide {
                -ms-overflow-style: none;
                scrollbar-width: none;
            }
            .scrollbar-hide::-webkit-scrollbar {
                display: none;
            }
            .text-shadow {
                text-shadow: 0 2px 4px rgba(0,0,0,0.1);
            }
            .card-hover {
                transition: all 0.3s ease;
            }
            .card-hover:hover {
                transform: translateY(-5px);
                box-shadow: 0 10px 20px rgba(0,0,0,0.08);
            }
            .bg-gradient-primary {
                background: linear-gradient(135deg, #165DFF 0%, #0E42B3 100%);
            }
            .progress-ring-circle {
                transition: stroke-dashoffset 0.35s;
                transform: rotate(-90deg);
                transform-origin: 50% 50%;
            }
            .animate-float {
                animation: float 3s ease-in-out infinite;
            }
            @keyframes float {
                0% { transform: translateY(0px); }
                50% { transform: translateY(-10px); }
                100% { transform: translateY(0px); }
            }
            .countdown-timer {
                letter-spacing: 0.1em;
            }
        }
    </style>
    -->
</head>
<body class="bg-gray-50 font-inter text-gray-800 min-h-screen flex flex-col">
    <!-- 顶部导航栏 -->
    <header class="bg-white shadow-sm sticky top-0 z-50 transition-all duration-300">
        <div class="container mx-auto px-4 py-3 flex items-center justify-between">
            <div class="flex items-center space-x-2">
                <a href="#" class="flex items-center">
                    <i class="fa fa-graduation-cap text-primary text-2xl mr-2"></i>
                    <h1 class="text-xl font-bold text-gray-800">学知题库</h1>
                </a>
            </div>
            
            <div class="hidden md:flex items-center space-x-6">
                <a href="#" class="text-gray-600 hover:text-primary transition-colors">首页</a>
                <a href="#" class="text-gray-600 hover:text-primary transition-colors">题库</a>
                <a href="#" class="text-gray-600 hover:text-primary transition-colors">学习路径</a>
                <a href="#" class="text-gray-600 hover:text-primary transition-colors">模拟考试</a>
                <a href="#" class="text-gray-600 hover:text-primary transition-colors">关于我们</a>
            </div>
            
            <div class="flex items-center space-x-4">
                <div class="flex space-x-2">
                    <button class="px-4 py-2 bg-white text-primary border border-primary rounded-lg hover:bg-primary/5 transition-colors">登录</button>
                    <button class="px-4 py-2 bg-primary text-white rounded-lg hover:bg-primary/90 transition-colors">注册</button>
                </div>
            </div>
        </div>
    </header>

    <!-- 主内容区（系统维护页面） -->
    <main class="flex-1 py-16 px-4">
        <div class="container mx-auto max-w-4xl">
            <div class="bg-white rounded-2xl shadow-lg overflow-hidden">
                <div class="relative overflow-hidden">
                    <!-- 装饰性背景 -->
                    <div class="absolute inset-0 bg-gradient-primary opacity-10"></div>
                    
                    <!-- 悬浮元素（增强视觉层次） -->
                    <div class="absolute top-1/4 left-1/4 w-32 h-32 bg-primary/10 rounded-full animate-float"></div>
                    <div class="absolute bottom-1/3 right-1/5 w-24 h-24 bg-secondary/10 rounded-full animate-float" style="animation-delay: 1s"></div>
                    
                    <!-- 核心内容区 -->
                    <div class="relative p-8 md:p-12 text-center">
                        <!-- 维护图标 -->
                        <div class="inline-block p-4 rounded-full bg-primary/10 mb-6">
                            <i class="fa fa-wrench text-5xl text-primary"></i>
                        </div>
                        
                        <!-- 标题与说明 -->
                        <h1 class="text-[clamp(2rem,5vw,3rem)] font-bold text-gray-800 mb-4">系统维护中</h1>
                        <p class="text-xl text-gray-600 mb-6 max-w-2xl mx-auto">
                            为了提供更好的服务体验，我们正在进行系统升级维护，期间部分功能可能无法正常使用。
                        </p>
                        
                        <!-- 维护时间提示 -->
                        <div class="bg-neutral rounded-xl p-6 mb-8 max-w-md mx-auto">
                            <p class="text-gray-700 mb-4">预计维护时间：</p>
                            <div class="flex flex-wrap justify-center gap-2 md:gap-4">
                                <div class="bg-white rounded-lg p-3 shadow-sm min-w-[60px]">
                                    <span id="hours" class="block text-2xl font-bold text-primary countdown-timer">02</span>
                                    <span class="text-sm text-gray-500">小时</span>
                                </div>
                                <div class="flex items-center text-gray-400">
                                    <span class="text-xl">:</span>
                                </div>
                                <div class="bg-white rounded-lg p-3 shadow-sm min-w-[60px]">
                                    <span id="minutes" class="block text-2xl font-bold text-primary countdown-timer">30</span>
                                    <span class="text-sm text-gray-500">分钟</span>
                                </div>
                                <div class="flex items-center text-gray-400">
                                    <span class="text-xl">:</span>
                                </div>
                                <div class="bg-white rounded-lg p-3 shadow-sm min-w-[60px]">
                                    <span id="seconds" class="block text-2xl font-bold text-primary countdown-timer">45</span>
                                    <span class="text-sm text-gray-500">秒</span>
                                </div>
                            </div>
                        </div>
                        
                        <!-- 维护原因说明 -->
                        <div class="mb-8 text-left max-w-2xl mx-auto bg-neutral rounded-xl p-6">
                            <h3 class="text-lg font-medium text-gray-800 mb-4">维护内容：</h3>
                            <ul class="space-y-3">
                                <li class="flex items-start">
                                    <i class="fa fa-check-circle text-success mt-1 mr-3"></i>
                                    <span class="text-gray-600">优化题库加载速度，提升做题体验</span>
                                </li>
                                <li class="flex items-start">
                                    <i class="fa fa-check-circle text-success mt-1 mr-3"></i>
                                    <span class="text-gray-600">新增学习数据分析功能，提供个性化推荐</span>
                                </li>
                                <li class="flex items-start">
                                    <i class="fa fa-check-circle text-success mt-1 mr-3"></i>
                                    <span class="text-gray-600">修复已知问题，增强系统稳定性</span>
                                </li>
                            </ul>
                        </div>
                        
                        <!-- 操作按钮 -->
                        <div class="flex flex-col sm:flex-row justify-center gap-4">
                            <button id="refresh-btn" class="px-6 py-3 bg-primary text-white rounded-lg hover:bg-primary/90 transition-colors inline-flex items-center justify-center">
                                <i class="fa fa-refresh mr-2"></i>刷新页面
                            </button>
                            <a href="mailto:contact@xuezhi.com" class="px-6 py-3 bg-white text-primary border border-primary rounded-lg hover:bg-primary/5 transition-colors inline-flex items-center justify-center">
                                <i class="fa fa-envelope mr-2"></i>联系我们
                            </a>
                        </div>
                    </div>
                </div>
            </div>
            
            <!-- 维护期间提示 -->
            <div class="mt-8 bg-white rounded-xl shadow-sm p-6">
                <h3 class="text-lg font-medium text-gray-800 mb-4 text-center">维护期间您可以：</h3>
                <div class="grid grid-cols-1 md:grid-cols-3 gap-4">
                    <div class="bg-neutral rounded-lg p-4 text-center card-hover">
                        <i class="fa fa-book text-primary text-2xl mb-3"></i>
                        <p class="text-gray-600">查看历史学习记录</p>
                    </div>
                    <div class="bg-neutral rounded-lg p-4 text-center card-hover">
                        <i class="fa fa-star text-primary text-2xl mb-3"></i>
                        <p class="text-gray-600">复习收藏的题目</p>
                    </div>
                    <div class="bg-neutral rounded-lg p-4 text-center card-hover">
                        <i class="fa fa-question-circle text-primary text-2xl mb-3"></i>
                        <p class="text-gray-600">浏览帮助中心内容</p>
                    </div>
                </div>
            </div>
        </div>
    </main>

    <!-- 页脚（保持全站一致性） -->
    <footer class="bg-gray-800 text-white py-12 mt-12">
        <div class="container mx-auto px-4">
            <div class="grid grid-cols-1 md:grid-cols-4 gap-8">
                <div>
                    <div class="flex items-center mb-4">
                        <i class="fa fa-graduation-cap text-primary text-2xl mr-2"></i>
                        <h3 class="text-xl font-bold">学知题库</h3>
                    </div>
                    <p class="text-gray-400 mb-4">智能教育资源平台，助力学生高效学习</p>
                    <div class="flex space-x-4">
                        <a href="#" class="text-gray-400 hover:text-white transition-colors">
                            <i class="fa fa-weibo"></i>
                        </a>
                        <a href="#" class="text-gray-400 hover:text-white transition-colors">
                            <i class="fa fa-wechat"></i>
                        </a>
                        <a href="#" class="text-gray-400 hover:text-white transition-colors">
                            <i class="fa fa-qq"></i>
                        </a>
                        <a href="#" class="text-gray-400 hover:text-white transition-colors">
                            <i class="fa fa-github"></i>
                        </a>
                    </div>
                </div>
                
                <div>
                    <h4 class="text-lg font-medium mb-4">快速链接</h4>
                    <ul class="space-y-2">
                        <li><a href="#" class="text-gray-400 hover:text-white transition-colors">首页</a></li>
                        <li><a href="#" class="text-gray-400 hover:text-white transition-colors">题库</a></li>
                        <li><a href="#" class="text-gray-400 hover:text-white transition-colors">学习路径</a></li>
                        <li><a href="#" class="text-gray-400 hover:text-white transition-colors">模拟考试</a></li>
                        <li><a href="#" class="text-gray-400 hover:text-white transition-colors">关于我们</a></li>
                    </ul>
                </div>
                
                <div>
                    <h4 class="text-lg font-medium mb-4">帮助中心</h4>
                    <ul class="space-y-2">
                        <li><a href="#" class="text-gray-400 hover:text-white transition-colors">常见问题</a></li>
                        <li><a href="#" class="text-gray-400 hover:text-white transition-colors">使用指南</a></li>
                        <li><a href="#" class="text-gray-400 hover:text-white transition-colors">意见反馈</a></li>
                        <li><a href="#" class="text-gray-400 hover:text-white transition-colors">联系我们</a></li>
                        <li><a href="#" class="text-gray-400 hover:text-white transition-colors">隐私政策</a></li>
                    </ul>
                </div>
                
                <div>
                    <h4 class="text-lg font-medium mb-4">联系我们</h4>
                    <ul class="space-y-2">
                        <li class="flex items-center">
                            <i class="fa fa-map-marker text-primary mr-2"></i>
                            <span class="text-gray-400">北京市海淀区中关村大街1号</span>
                        </li>
                        <li class="flex items-center">
                            <i class="fa fa-phone text-primary mr-2"></i>
                            <span class="text-gray-400">400-123-4567</span>
                        </li>
                        <li class="flex items-center">
                            <i class="fa fa-envelope text-primary mr-2"></i>
                            <span class="text-gray-400">contact@xuezhi.com</span>
                        </li>
                        <li class="flex items-center">
                            <i class="fa fa-clock-o text-primary mr-2"></i>
                            <span class="text-gray-400">周一至周日 9:00-21:00</span>
                        </li>
                    </ul>
                </div>
            </div>
            
            <div class="border-t border-gray-700 mt-8 pt-8 text-center text-gray-400">
                <p>&copy; 2025 学知题库 版权所有 | 京ICP备12345678号</p>
            </div>
        </div>
    </footer>

    <!-- JavaScript（交互增强） -->
    <script>
        // 导航栏滚动效果
        window.addEventListener('scroll', function() {
            const header = document.querySelector('header');
            if (window.scrollY > 50) {
                header.classList.add('py-2');
                header.classList.remove('py-3');
                header.classList.add('shadow');
            } else {
                header.classList.add('py-3');
                header.classList.remove('py-2');
                header.classList.remove('shadow');
            }
        });

        // 倒计时功能
        function updateCountdown() {
            // 模拟维护倒计时（实际项目中可从后端获取结束时间）
            const hoursEl = document.getElementById('hours');
            const minutesEl = document.getElementById('minutes');
            const secondsEl = document.getElementById('seconds');
            
            let hours = parseInt(hoursEl.textContent);
            let minutes = parseInt(minutesEl.textContent);
            let seconds = parseInt(secondsEl.textContent);
            
            seconds--;
            
            if (seconds < 0) {
                seconds = 59;
                minutes--;
            }
            
            if (minutes < 0) {
                minutes = 59;
                hours--;
            }
            
            if (hours < 0) {
                // 倒计时结束，提示用户
                hours = 0;
                minutes = 0;
                seconds = 0;
                document.querySelector('h1').textContent = '维护已完成';
                document.querySelector('p.text-xl').textContent = '系统维护已完成，您可以正常使用所有功能了';
            }
            
            // 补零显示
            hoursEl.textContent = hours.toString().padStart(2, '0');
            minutesEl.textContent = minutes.toString().padStart(2, '0');
            secondsEl.textContent = seconds.toString().padStart(2, '0');
        }
        
        // 每秒更新一次倒计时
        setInterval(updateCountdown, 1000);

        // 刷新按钮功能
        document.getElementById('refresh-btn').addEventListener('click', function() {
            this.innerHTML = '<i class="fa fa-spinner fa-spin mr-2"></i>刷新中...';
            this.disabled = true;
            
            // 模拟刷新延迟
            setTimeout(() => {
                window.location.reload();
            }, 800);
        });

        // 返回顶部按钮
        const backToTopButton = document.createElement('button');
        backToTopButton.id = 'backToTop';
        backToTopButton.className = 'fixed bottom-6 right-6 bg-primary text-white w-12 h-12 rounded-full flex items-center justify-center shadow-lg opacity-0 transition-opacity duration-300 hover:bg-primary/90';
        backToTopButton.innerHTML = '<i class="fa fa-arrow-up"></i>';
        document.body.appendChild(backToTopButton);
        
        window.addEventListener('scroll', function() {
            if (window.scrollY > 300) {
                backToTopButton.classList.add('opacity-100');
                backToTopButton.classList.remove('opacity-0');
            } else {
                backToTopButton.classList.add('opacity-0');
                backToTopButton.classList.remove('opacity-100');
            }
        });
        
        backToTopButton.addEventListener('click', function() {
            window.scrollTo({
                top: 0,
                behavior: 'smooth'
            });
        });
    </script>
</body>
</html>